//
//  UIButton+UIButton.m
//  saler-ios
//
//  Created by 王亚陆 on 17/5/31.
//  Copyright © 2017年 sayimba. All rights reserved.
//

#import "UIButton+UIButton.h"

@implementation UIButton (UIButton)

+ (UIButton *)createUIbutton:(NSString *)title
                     andFont:(CGFloat)font
                    andColor:(UIColor*)color{
    
    
    UIButton * btn = [UIButton buttonWithType:UIButtonTypeCustom];
    [btn setTitle:title forState:UIControlStateNormal];
    btn.titleLabel.font = Font(font);
    [btn setTitleColor:color forState:UIControlStateNormal];
    
    return btn;
}

+ (UIButton *)createUIbutton:(NSString *)title
                     andFont:(CGFloat)font
                    andColor:(UIColor*)color
                andBackColor:(UIColor*)backclor
                      andTag:(int)tag
{
    
    
    UIButton * btn = [self createUIbutton:title andFont:font andColor:color];
    btn.backgroundColor = backclor;
    btn.tag = tag;
    return btn;
}



@end
